svn up .
svn up tgk/
svn up pubdoc/
svn up gkstatic/
svn up release/

TARGET_DIR=tgk/
R=${r:--1}
R_s=false
for i in $@
    do case $i in
        -r)
            R_s=true
            ;;
        *)
            if $R_s ; then
                R=$i
            fi
            ;;
    esac
done
LEN=${2:-1}
case $1 in
    sync)
        if $R_s; then
            for f in `svn log -r $R -v . | sed -n '/^   [MDU] /p' | awk '{print $2}' | cut -c8-` ; do cp $f $TARGET_DIR$f
                echo $TARGET_DIR$f; done
        else
            svn log -l$LEN -v . | sed -n '/^   [MDU] /p' | awk '{print $2}'
        fi
        ;;
    *)
        ;;
esac
